import request from '@/utils/request'
//用户删除
export function userDelete(id) {
    return request({
      url:`/user/delete?id=${id}`,
      method: 'post',
    })
  }
//用户修改密码
  export function updatePass(data) {
    return request({
      url:'/user/update/password',
      method: 'post',
      data
    })
  }
//禁用设备
  export function userDisable(id,status) {
    return request({
      url:'/user/disable'+'?id='+id+'&status='+status,      
      method: 'post',
    })
  }
//用户列表
export function userList(data) {
    return request({
      url: '/user/list',
      method: 'POST',
      data
    })
  }
//角色列表
export function roleList() {
  return request({
    url: '/role/list',
    method: 'get',
  })
}
//修改
export function userSave(data) {
  return request({
    url: '/user/save',
    method: 'post',
    data
  })
}




// 获取角色列表
export function getrolelist(data) {
  return request({
    url:'/role/list',
    method: 'get',
    data: data
  })
}

// 获取角色权限
export function permissionrole() {
return request({
  url:'/user/all/menu/tree',
  method: 'get',
})
}